import Request from "./axios"

const axios = new Request({
  baseURL: '/touka',
  withDirectives: true,
  interceptors: {
    requestInterceptor: async (config) => {
      // console.log('请求成功拦截-实例')
      return config
    },
    requestInterceptorCatch: (err) => {
      // console.log('请求失败拦截-实例')
      return err
    },
    responseInterceptor: (res) => {
      // console.log('响应成功拦截-实例')
      return res
    },
    responseInterceptorCatch: (err) => {
      // console.log('响应失败拦截-实例')
      return err
    },
  },
})

export default axios

// const axios = Axios.create({
//   baseURL: '/touka',
//   withDirectives: true
// })
// export default axios